package com.bjpowernode.controller;


import com.bjpowernode.beans.User;
import com.bjpowernode.services.UserServices;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;

@RestController
@RequestMapping("/user")
public class UserController {


    @Autowired
    UserServices userServices;

    @RequestMapping("getAll.action")
    public ArrayList<User> getAll(){
        ArrayList<User> all = userServices.getAll();
        return all;
    }
}
